package com.example.constellation.util;

import java.text.SimpleDateFormat;
import java.util.Date;

public class URLContent {
    //星座配对接口
    public static String getParnterURL(String man,String woman){
        man=man.replace("座","");
        woman=woman.replace("座","");
        String url="http://api.tianapi.com/xingzuo/index?key=d13556b221aae0c5b6128fc9aadeba6e&me="+man+"&he="+woman;
        return url;
    }

    //星座运势接口
    public static String getLuckURL(String name){
//        System.out.println("name="+name);
        Date date=new Date();
        SimpleDateFormat sdf=new SimpleDateFormat("YYYY-MM-dd");
        String now=sdf.format(date);
        String url="http://api.tianapi.com/star/index?key=d13556b221aae0c5b6128fc9aadeba6e&astro="+name+"&date="+now;
//        System.out.println("url="+url);
        return url;
    }
}
